﻿Public Interface INamesData

#Region "Names"

    Function GetNameFull(ByVal nameId As Guid) As String
    Function GetName(ByVal nameId As Guid) As TaxonNamesInterface.Name
    Function GetNameChildren(ByVal nameId As Guid) As List(Of TaxonNamesInterface.Name)
    Sub DeleteNameRecord(ByVal nameLsid As String, ByVal newNameLsid As String, ByVal user As String)
    Sub InsertUpdateName(ByVal n As TaxonNamesInterface.Name, ByVal user As String)
    Sub DeleteNameAuthors(ByVal nameId As Guid)
    Function InsertUpdateNameAuthor(ByVal nameAuthorId As Integer, ByVal nameId As Guid, ByVal basAuthors As String, ByVal combAuthors As String, ByVal basExAuth As String, ByVal combExAuth As String, ByVal isCorrected As Boolean, ByVal user As String) As TaxonNamesInterface.NameAuthor
    Function GetNameAuthors(ByVal nameId As Guid) As List(Of TaxonNamesInterface.NameAuthor)
    Function SearchNames(ByVal searchText As String, ByVal anywhereInText As Boolean) As List(Of TaxonNamesInterface.Name)
    Function GetNameSynonyms(ByVal nameId As Guid) As List(Of TaxonNamesInterface.Name)
    Function GetNameLSIDs(ByVal pageNumber As Integer, ByVal pageSize As Integer) As List(Of String)
    'todo ?
    'Function GetChildNames(ByVal parentNameId As Guid, ByVal recurseChildren As Boolean) As List(Of TaxonNamesInterface.Name)

#End Region

#Region "Field Status"

    Sub InsertUpdateFieldStatus(ByVal recordId As String, ByVal fieldStatusId As Integer, ByVal statusLevelFk As Integer, ByVal user As String)
    'Sub InsertFieldStatus(ByVal recordId As String, ByVal tableName As String, ByVal fieldName As String, ByVal statusLevelFk As Integer, ByVal user As String)

#End Region

#Region "Concept"

    Function GetConcept(ByVal conceptId As Guid) As TaxonNamesInterface.Concept
    Sub UpdateConcept(ByVal conc As TaxonNamesInterface.Concept, ByVal user As String)

#End Region

#Region "ConceptRelationship"

    Function GetRelationshipTypes() As List(Of TaxonNamesInterface.RelationshipType)
    Function GetNameConcepts(ByVal nameId As Guid) As List(Of TaxonNamesInterface.Concept)
    Function GetNameConceptRelationshipRecords(ByVal nameId As Guid, ByVal includeToConcepts As Boolean) As List(Of TaxonNamesInterface.ConceptRelationship)
    Function GetConceptRelationship(ByVal ConceptRelId As Guid) As TaxonNamesInterface.ConceptRelationship
    Sub UpdateConceptRelationship(ByVal cr As TaxonNamesInterface.ConceptRelationship, ByVal user As String)
    Sub DeleteConceptRelationship(ByVal ConceptRelLSID As String, ByVal NewConceptRelLSID As String, ByVal user As String)

#End Region

#Region "Import"
    'todo

    'Function GetImportTypes() As ImportType()    
    'Function InsertUpdateImport(ByVal imp As Import, ByVal user As String) As Boolean

#End Region

#Region "Ranks"

    Function GetRanks() As List(Of TaxonNamesInterface.Rank)
    Function RankById(ByVal id As Guid) As TaxonNamesInterface.Rank
    Function RankByName(ByVal name As String) As TaxonNamesInterface.Rank

#End Region

End Interface
